import request from '@/utils/request'

// 查询医生排班列表
export function listPaiban_management(query) {
  return request({
    url: '/ds/list',
    method: 'get',
    params: query,
  })
}

// 查询医生排班详细
export function getPaiban_management(scheduleId) {
  return request({
    url: '/ds/' + scheduleId,
    method: 'get'
  })
}

// 新增医生排班
export function addPaiban_management(data) {
  return request({
    url: '/ds',
    method: 'post',
    data: data
  })
}

// 修改医生排班
export function updatePaiban_management(data) {
  return request({
    url: '/ds',
    method: 'put',
    data: data
  })
}

// 删除医生排班
export function delPaiban_management(scheduleId) {
  return request({
    url: '/ds/' + scheduleId,
    method: 'delete'
  })
}



//查询当前可分配的排班时间ID
export function selectUseable() {
  return request({
    url: '/std/selectUseable',
    method: 'get'
  })
}

//插入一条可分配的排班时间ID
export function insertUseable() {
  return request({
    url: '/std/insert',
    method: 'post'
  })
}

//通过id删除  时间排班记录
export function deleteScheduleTimeDistributionByid(id) {
  return request({
    url: '/std/deleteByid/'+id,
    method: 'delete',
  })
}
